package com.netqin.netconnection;

import android.os.Message;

/**
 * 单个下载任务接口类
 * 
 * @author MingLi
 * @since 2011-11-10
 */
public interface FileDownloadTask {

    enum TaskStatusCode
    {        
        Succeeded,//成功
        Failed//失败
    }    
    
    /**
     * 
     * 获取当前任务的下载状态
     */
    public TaskStatusCode  getStatus();
    
    
     /**
     * 获取当前下载任务相关的msg
     *
     * @note Performs a shallow copy of the data field.
     * Does not copy the linked list fields, nor the timestamp or
     * target/callback of the original message.
     *
     */
    public Message  getMessage();
    
    /**
     * 获取当前下载任务相关的本地缓存路径
     * 
     */
    public String  getFilePath();
    
    /**
     * 获取当前下载任务相关的url
     * 
     */
    public String  getUrl();
}
